//*****************************************************************************
//
// ABEC3 Observation Script
// Project: IB-Cone-CircSym
//
//*****************************************************************************

Nodes "Contour"
  Scale=0.001        // Millimeter 
  Shift=-70mm
  10     20    0  
  20     15   20
  30      2   35     // Radius dust cap
  40     75  125     // Cone radius
  50     75  135     // Suspension and inner interface radius
  60     95  135     // Outer interface radius
  70     95    0     // Outer Interface
  100    75  500     // Contour map   75  500
  110   500  500

Nodes "Spectrum"
  Scale=0.001        // Millimeter 
  1001  300   10     // Spectrum point
  1002 1000   50


// Display of pressure-field in ABEC-Viewer.
// Each line creates a contour plane. There are two vertices only.
// In circular symmetric case the other two vertices are always at the center.
// In this example we create two contours, 
// the first starting at node 30 going to node 40
// and completing the polygon via the associated points at the center.

Field  "Contour1"
  RefNodes="Contour"      // Where to get the vertices from.
  EdgeLength=40mm         // Min edge-length of basic contour grid elements.
  BodeType=LeveldB        // Component of complex-number to display, here SPL.
  StepSize=1              // Step size of contour-levels, here SPL.
  Range=50dB              // SPL-Range
  Alpha=0.5               // Transparency (comment out for default)
  1   30   40             // Contour of inner part.
  2  100  110             // Contour of outer field.


// VACS

// This section of script outputs spectra to VACS. In order to make this
// work you would need Vacs.exe or VacsViewer.exe installed, which you can
// download from www.vacsviewer.com. 

// Because VACS works as a server it needs some link-ID to recognize connections between
// an observation point definition here in ABEC and a curve in VACS. These links can be
// any string without blanks. ABEC generates unique IDs for you at
// "Misc/Copy VACS ID" for pasting from clipboard, however you may also use your own.


// "Control_Spectrum" provides a tree-view-folder for ABEC in VACS.
// The abscissa for all spectral analysis is defined in "Control_Spectrum".
// Note, that it is possible to specify a different frequency resolution at observation stage
// than as specified at "Control_Solver". If nescessary ABEC performs a frequency interpolation
// of the surface single and double layer potentials prior to integration of
// the Helmholtz-Integral. The interpolation makes use of the Continous Phase Technique.
// The results are exact (within the realm of approximation of meshing) if there are
// sufficient solving points. However even if this is not the case, useful first order
// approximations can be achieved.

Control_Spectrum
  Name="Cone-IB-Test"
  VacsID=ID966625641
  f1=10; f2=5000;  NumFrequencies=100;  Abscissa=log


// Spectrum of sound pressure at a set of observation points.
// Each line consists of <Index> <RefIndex> <VACS link-ID>. The ref-index
// takes reference to the node-list.

off BE_Spectrum "Points"
  PlotType=Curves
  RefNodes="Spectrum"
  GraphHeader="Sample points"
  1  1001  VacsID=ID66625642
  2  1002  VacsID=ID51765798


// Radiation impedance of diaphragm-front side.
// With RadImpType=Normalized the values
// are normalized to roh*c.

Radiation_Impedance 
  GraphHeader="Radiation Impedance"
  BodeType=Complex
  Range_min=-1;  Range_max= 2
  RadImpType=Normalized
  101 1001 1001 VacsID=ID6551234


// Spectrum of sound pressure at a range of circular distributed
// observation points. This results in a contour-frequency-directivity-plot
// in VACS where details can be observed and processed further.
// Note, that in the circular-sysmmetric case all elevation angles
// would yield identical results.

off BE_Spectrum "Directivity"
  PlotType=Directivity
  PolarRange=-90, 90, 37
  Distance=100cm
  BasePlane=Pos
  101  0.0   VacsID=ID6551765799


// Lumped Element Observations
// Current into port 1 of Driver, which are the
// electrical terminals.

LE_Spectrum "Current"
  GraphHeader="Current into driver"
  AnalysisType=Current
  BodeType=Ampl
  System="S1"
  101  "Drv1"  Port=1   VacsID=ID1


// Voltage across driver-terminals, which is
// not constant because of high-pass.

LE_Spectrum
  GraphHeader="Voltage across driver terminals"
  AnalysisType=Voltage
  BodeType=Ampl
  System="S1"
  101  "Drv1"  Port=1   VacsID=ID2
